# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
pkgname=ruby-jekyll-sass-converter
_gemname=jekyll-sass-converter
pkgver=2.2.0
pkgrel=2
pkgdesc="A Sass converter for Jekyll"
url="https://github.com/jekyll/jekyll-sass-converter"
arch="noarch"
license="MIT"
depends="ruby ruby-sassc~2"
source="https://github.com/jekyll/jekyll-sass-converter/archive/v$pkgver/$_gemname-$pkgver.tar.gz
	gemspec.patch
	"
builddir="$srcdir/$_gemname-$pkgver"
options="!check"  # circular dependency with jekyll

build() {
	gem build $_gemname.gemspec
}

package() {
	local gemdir="$pkgdir/$(ruby -e 'puts Gem.default_dir')"

	gem install \
		--local \
		--install-dir "$gemdir" \
		--ignore-dependencies \
		--no-document \
		--verbose \
		$_gemname

	# Remove unnecessary files and rubbish...
	cd "$gemdir"
	rm -r cache build_info doc extensions
}

sha512sums="
2704defb5ded854afb3620e876045e222e3f4bf03344f9a060fcfc0b1f2e6bebfef776aff69e592ba8484516060d4c5a75499fc343fcab5f9c96cc2f6658f344  jekyll-sass-converter-2.2.0.tar.gz
83810f03ac8fcc2aa70a7d82a191f2a350d8e81e0421e342c1cac4687e13daf2b4edba93ca70e167c3a6203b5bd968769832bcf1da1fa55813ec93dcae905699  gemspec.patch
"
